<!doctype html>
<html lang="en">
<head>
    <title>登录</title>
    <th:block th:replace="common/common::common_header"/>
</head>
<body class="login-bg">

<div class="login">
    <div class="message">WeAdmin 1.0-管理登录</div>
    <div id="darkbannerwrap"></div>

    <form method="post" class="layui-form">
        <input name="username" placeholder="用户名" type="text" lay-verify="required" class="layui-input">
        <hr class="hr15">
        <input name="password" lay-verify="required" placeholder="密码" type="password" class="layui-input">
        <hr class="hr15">
        <input class="loginin" value="登录" lay-submit lay-filter="login" style="width:100%;" type="submit">
        <hr class="hr20">
        <div>
            前端静态展示，请随意输入，即可登录。
        </div>
    </form>
</div>


<!-- 底部结束 -->
</body>
<th:block th:replace="common/common::common_js"/>
<script type="text/javascript">

    layui.extend({
        admin: '/resource/plugin/weAdmin/static/js/admin'
    });
    layui.use(['form', 'admin'], function () {
        var form = layui.form
            , admin = layui.admin;
        // layer.msg('玩命卖萌中', function(){
        //   //关闭后的操作
        //   });
        //监听提交
        form.on('submit(login)', function (data) {
            // alert(888)
            layer.msg(JSON.stringify(data.field), function () {
                location.href = '/index/toHome'
            });
            return false;
        });
    });
</script>
</html>